package bit2;

import java.util.*;

public class bitMain12 {
    public boolean wordBreak(String s, Set<String> dict) {
        boolean[] canBreak=new boolean[s.length()+1];
        canBreak[0]=true;
        for (int i = 0; i <=s.length(); i++) {
            for (int j = 0; j < i; j++) {
                if (canBreak[j]&&dict.contains(s.substring(j,i))){
                    canBreak[i]=true;
                    break;
                }
            }
        }
        return canBreak[s.length()];
    }
    public static void main(String[] args) {
        HashSet<String> set=new HashSet<>();
        Scanner in=new Scanner(System.in);
        while (in.hasNext()){
            String str=in.nextLine();
            String[] strings=str.split(" ");
            for (int i = 0; i < strings.length; i++) {
                set.add(strings[i]);
            }
        }
        System.out.println(set.size());
    }
    public static int fib(int n){
        if(n<=0){
            return 0;
        }
        if (n==1||n==2){
            return 1;
        }
        return fib(n-1)+fib(n-2);
    }
    public static void main1(String[] args) {

            Scanner in=new Scanner(System.in);
            int min=Integer.MAX_VALUE;
            int N=in.nextInt();
            for (int i = 0; i <= 20; i++) {
                if(Math.abs(fib(i)-N)<min){
                    min=Math.abs(fib(i)-N);
                }
            }
            System.out.println(min);
    }
}
